package com.pro.service.impl;

import com.pro.entry.JsUserCollection;
import com.pro.mapper.JsUserCollectionMapper;
import com.pro.service.JsUserCollectionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Date;

/**
 * ClassName:JsUserCollectionServiceImple
 * Package:com.pro.service.impl
 * Description:
 *
 * @Date:2022/4/13 9:36
 * @Author: ZPT
 */
@Service
public class JsUserCollectionServiceImple implements JsUserCollectionService {

    @Autowired(required = false)
    private JsUserCollectionMapper collectionMapper;

    /**
     * @author ZPT
     * @content :添加收藏记录
     */
    @Override
    public Boolean addCollection(JsUserCollection userCollection) {
        userCollection.setCollectionDate(new Date());
        return collectionMapper.addCollection(userCollection);
    }
}
